third-party-exp-api icon

third-party-exp-api

(0 reviews)

Aramex- Create Shipment

Description: This API is used to create shipment in aramex.

Mulesoft Request:

Headers:

Mandatory Headers: x-correlation-id, client_id, Authorization

Optional Headers: x-sub-channel-id, x-user-id, x-debug-flag, x-customer-id, client_secret, x-channel-id, x-bank-id

Paramaters:

URI Params: NA

Query Params: NA

Body:

{
    "shipments": [
        {
            "consignee": {
                "reference1": "999",
                "reference2": "888",
                "accountNumber": "",
                "address": {
                    "line1": "salah El Din Al Ayoubi street",
                    "line2": "",
                    "line3": "",
                    "city": "Amman",
                    "stateOrProvinceCode": "Alabama",
                    "postCode": "",
                    "countryCode": "JO",
                    "longitude": "0",
                    "latitude": "0",
                    "buildingNumber": "",
                    "buildingName": "",
                    "floor": "",
                    "apartment": "",
                    "description": ""
                },
                "contact": {
                    "department": "",
                    "personName": "Hanna H. Rabah",
                    "title": "",
                    "companyName": "Hanna H. Rabah",
                    "phoneNumber1": "0797005096",
                    "phoneNumber1Ext": "",
                    "phoneNumber2": "",
                    "phoneNumber2Ext": "",
                    "faxNumber": "",
                    "cellPhone": "0797005096",
                    "emailAddress": "test@test.com",
                    "type": ""
                }
            },
            "thirdParty": {
                "reference1": "",
                "reference2": "",
                "accountNumber": "20016",
                "address": {
                    "line1": "UTS",
                    "line2": "Sulaymaniyah - Test Area",
                    "line3": "",
                    "city": "Amman",
                    "stateOrProvinceCode": "",
                    "postCode": "",
                    "countryCode": "JO",
                    "longitude": "0",
                    "latitude": "0",
                    "buildingNumber": "",
                    "buildingName": "",
                    "floor": "",
                    "apartment": "",
                    "description": ""
                },
                "contact": {
                    "department": "",
                    "personName": "UST",
                    "title": "",
                    "companyName": "UST",
                    "phoneNumber1": "0797005096",
                    "phoneNumber1Ext": "",
                    "phoneNumber2": "",
                    "phoneNumber2Ext": "",
                    "faxNumber": "",
                    "cellPhone": "0797005096",
                    "emailAddress": "cs@gaashwd.com",
                    "type": ""
                }
            },
            "shippingDateTime": "2023-07-31T15:38:47.6927242-05:00",
            "dueDate": "2023-07-31T15:38:47.6912227-05:00",
            "comments": "This is a test",
            "pickupLocation": "Reception",
            "operationsInstructions": "Please take care ... fragile",
            "accountingInstructions": "Give us a good price",
            "details": {
                "dimensions": {
                    "length": 10,
                    "width": 10,
                    "height": 10,
                    "unit": "CM"
                },
                "actualWeight": {
                    "unit": "KG",
                    "value": 0.5
                },
                "chargeableWeight": {
                    "unit": "KG",
                    "value": 0.5
                },
                "descriptionOfGoods": "Consumer electronics accessories",
                "goodsOriginCountry": "JO",
                "numberOfPieces": 1,
                "productGroup": "DOM",
                "productType": "ONP",
                "paymentType": "P",
                "services": "",
                "customsValueAmount": {
                    "currencyCode": "USD",
                    "value": 5
                },
                "cashOnDeliveryAmount": {
                    "currencyCode": "USD",
                    "value": 0
                },
                "cashAdditionalAmountDescription": "",
                "transportType": "0",
                "items": [
                    {
                        "packageType": "general",
                        "weight": {
                            "value": 10,
                            "unit": "KG"
                        },
                        "quantity": 1,
                        "comments": "general"
                    }
                ]
            }
        }
    ],
    "labelInfo": {
        "reportId": 9729,
        "reportType": "URL"
    }
}

Content-type: application/json, text/json

Mulesoft Response:

Success Response: (201)

{
    "status": {
        "success": true,
        "code": "201",
        "arabicMessage": "تمت العملية بنجاح",
        "englishMessage": "The Operation has been Successfully Completed"
    },
    "response": {
        "shipmentId": "44164148302",
        "shipmentLabel": "https://ws.sbx.aramex.net/content/rpt_cache/cac440211311496ab6d16d8bfc9ad9f0.pdf",
        "shipmentAttachmentName": "ShipmentItems_dee2132bea9349dc801c8ecfbf58bb86.pdf",
        "shipmentAttachmentType": "General",
        "shipmentAttachmentUrl": "https://ws.sbx.aramex.net/content/rpt_cache/ShipmentItems_dee2132bea9349dc801c8ecfbf58bb86.pdf"
    }
}

Error Response: (400, 403, 404, 405, 406, 415, 500, 501)

{
    "status": {
        "success": false,
        "code": "400",
        "reasonCode": "BadRequest",
        "arabicMessage": "لا يمكن اتمام العملية - حركة غير موجوده",
        "englishMessage": "Shipper.PartyAddress.CountryCode - Country Code is empty",
        "backendError": "Shipper.PartyAddress.CountryCode - Country Code is empty",
        "backendCode": "REQ11"
    }
}

Reviews